package com.cslg.ac.demo.constant;

import java.lang.reflect.Field;


public class MessageType {

	public static final int SYSTEM_INFORM = 1;//系统通知
	
	public static final int COMMENT = 2;//评论通知

	public static final int LIKE = 3;//点赞通知
	
	public static final int CHATTING = 4;//聊天通知

	public static final int COMMUNITY_POST = 5; //社区动态通知

	public static final int PERSONAL_POST = 6; //个人动态通知
	
	public static boolean isMessageType(int messageType)
	{
		Field[] fields = MessageType.class.getFields();
		for(Field field : fields)
		{
			try
			{
				if(field.getInt(MessageType.class) == messageType)
					return true;
			}
			catch (Exception e)
			{
				e.printStackTrace();
			}
		}
		return false;
	}
}
